using System.Collections.Generic;

namespace ThridGroup.ERP.Application.Contracts.DTO.WarehouseManagement
{
    /// <summary>
    /// 分页结果DTO
    /// </summary>
    /// <typeparam name="T">数据类型</typeparam>
    public class PagedResultDto<T>
    {
        /// <summary>
        /// 总记录数
        /// </summary>
        public int Total { get; set; }

        /// <summary>
        /// 当前页数据
        /// </summary>
        public List<T> Items { get; set; } = new List<T>();
        
        /// <summary>
        /// 响应代码
        /// </summary>
        public int Code { get; set; } = 0;
        
        /// <summary>
        /// 响应消息
        /// </summary>
        public string Msg { get; set; } = "成功";
        
        /// <summary>
        /// 数据计数（同Total）
        /// </summary>
        public int Count => Total;
        
        /// <summary>
        /// 数据
        /// </summary>
        public List<T> Data => Items;
    }
} 